package packet;

import java.io.Serializable;
import java.util.LinkedList;

import sql.WritePicSound;

import TCP.Communication.CommunicationServer;
import TCP.Communication.LinkerClient;
import TCP.Communication.LinkerServer;
import TCP.Packet.sys.Packet_i;

public class SendPicSound implements Packet_i,Serializable{
	public LinkedList<byte[]> bList = new LinkedList<byte[]>();
	public String name;
	public void setlist(LinkedList<byte[]> p) {
		bList = p;
	}

	@Override
	public void runOnServer(LinkerServer ls) {
		CommunicationServer.cs.sendTo指定名稱(ls, this, new String[]{"sql"});
		System.out.println("SendPicSound");
	}

	@Override
	public void runOnClient(LinkerClient lc) {
		WritePicSound w=new WritePicSound();
		w.WriteFile(bList, name);
		
	}
	
	
}
